import { createStore } from 'vuex'

export default createStore({
  state: {
    playList: [{  //播放列表
      al: {
        id: 35005583,
        name: "水星记",
        pic: 2946691248081599,
        picUrl: "https://p1.music.126.net/wSMfGvFzOAYRU_yVIfquAA==/2946691248081599.jpg",
        pic_str: "109951167040040692"
      },
      id: 441491828
    }],
    playListIndex: 0,   //默认下标为0
    isbtnShow: true   //暂停按钮的显示
  },
  getters: {
  },
  mutations: {
    updataIsbtnShow(state, value) {
      state.isbtnShow = value
    },
    updataPlayList(state, value) {
      state.playList = value
      console.log(state.playList);
    },
    updataPlayListIndex(state, value) {
      state.playListIndex = value
    }
  },
  actions: {
  },
  modules: {
  }
})
